<html>
<head>
<meta http-equiv=Content-Type content=text/html;charset=utf-8>
<#include "../inc/commonJs.html">
<script type="text/JavaScript">
	function saveProject(obj){
		var url = "<#if projectid??>editProject.do?projectid=${projectid}<#else>addProject.do</#if>";
		$('form').form('submit',{  
		    url:url,
		    onSubmit:function(){
				return $(this).form('validate');
		    },  
		    success:function(data){ 
		    	obj.tree('reload');
				top.closemodalwindow(true, data);
		    }  
		});
	}
	//
	$(function(){
		var url = window.location.href;
		if(url.indexOf('windowparam')!=-1){
			var params = url.substring(url.lastIndexOf('windowparam')+12,url.length);
			if(params!=''&&params!=0){
				$('#fid').combobox('setValue',params);
			}
		}else{
			if('${obj.fid!}'!=0){
				$('#fid').combobox('setValue','${obj.fid!}');
			}
		}
		$('#starttime').datebox('setValue', '${obj.starttime!}');
		$('#stoptime').datebox('setValue', '${obj.stoptime!}');
		$('#zt').val('${obj.zt!}');
	})
</script>

</head>
<body>
<form method="post" name="flmxForm" id="flmxForm">
	<table border="0" align="center" width="90%" cellspacing="0" cellpadding="0" class="table_all" style="margin-top:5px">
      <tr>
        <td height="35" class="td_table_1"><div align="center">上级项目：</div></td>
        <td height="35" class="td_table_2">&nbsp;
        	<input id="fid" class="easyui-combobox" name="fid" style="width:200px;" data-options="valueField:'projectid',textField:'name',url:'listProjectForCombox.do'" panelHeight="150" />
         </td>
      </tr>
      <tr>
        <td width="30%" height="35" class="td_table_1" valign="middle"><div align="center"><span class="smallFont">项目名称：<font color=red>*</font></span></div></td>
        <td width="70%" height="35" class="td_table_2"><div align="left">&nbsp;
        <input class="easyui-validatebox" type="text" required="true" id="name" name="name" maxlength="30" style="width:200px;" value="${obj.name!}">
          </div></td>
      </tr>
      <tr>
        <td width="30%" height="35" class="td_table_1" valign="middle"><div align="center"><span class="smallFont">开始时间：</span></div></td>
        <td width="70%" height="35" class="td_table_2"><div align="left">&nbsp;
        <div class="easyui-datebox" id="starttime" name="starttime" style="width:200px;" panelWidth="200"></div>
        </td>
      </tr>
      <tr>
        <td width="30%" height="35" class="td_table_1" valign="middle"><div align="center"><span class="smallFont">结束时间：</span></div></td>
        <td width="70%" height="35" class="td_table_2"><div align="left">&nbsp;
        <div class="easyui-datebox" id="stoptime" name="stoptime" style="width:200px;" panelWidth="200"></div>
        </td>
      </tr>
    <tr>
      <td width="30%" height="35" class="td_table_1"><div align="center">状态：<font color=red>*</font></div></td>
      <td width="70%" height="35" class="td_table_2">&nbsp;
      	<select size="1" name="zt" id="zt"  class="easyui-combobox"  >
			<option selected value="0">正常</option>
			<option value="1">未启动</option>
			<option value="2">延期</option>
			<option value="3">暂停</option>
		</select>
      </td>
    </tr> 
    <tr>
      <td width="30%" height="35" class="td_table_1"><div align="center">介绍：</div></td>
      <td width="70%" height="35" class="td_table_2">&nbsp;
      <textarea rows="12" name="content" style="width:300px;">${obj.content!}</textarea>
      </td>
    </tr>    
  </table>
</form>
</body>
</html>